from django.urls import path
from . import views

app_name = 'users'

urlpatterns = [
    path('', views.StudentListView.as_view(), name='student_list'),
    path('create/', views.student_create, name='student_create'),
    path('<uuid:pk>/edit/', views.student_update, name='student_edit'),
    path('<uuid:pk>/delete/', views.student_delete, name='student_delete'),
    path('<uuid:pk>/detail/', views.student_detail, name='student_detail'),
    path('search/', views.StudentListView.as_view(), name='student_search'),
    path('<uuid:student_id>/past-score/add/', views.past_score_create, name='past_score_add'),
    path('<uuid:student_id>/past-score/<int:score_id>/update/', views.past_score_update, name='past_score_update'),
    path('<uuid:student_id>/past-score/<int:score_id>/delete/', views.past_score_delete, name='past_score_delete'),
    path('<uuid:student_id>/study-goal/add/', views.study_goal_create, name='study_goal_add'),
    path('<uuid:student_id>/target-scores/create/', views.target_score_create, name='target_score_create'),
    path('<uuid:student_id>/target-scores/<int:target_id>/update/', views.target_score_update, name='target_score_update'),
    path('<uuid:student_id>/target-scores/<int:target_id>/delete/', views.target_score_delete, name='target_score_delete'),

    path('login/', views.user_login, name='user_login'),  # 登录路由
    path('logout/', views.user_logout, name='user_logout'),  # 登出路由

]
